Modulation transfer function of an image

ABSTRACT

The border of object in an image is blurred and so the modulation transfer function (MTF) of an image is reduced due to the blurred border. This present invention provides a deductive method for determining a border of an object in an image. Then the border of the object therein is amended and so the MTF of image is increased. In regard to an increasingly changeable color image, the present invention provides a deductive method in deciding upon a gray scale of the image to increase the color accuracy in amending an image.

BACKGROUND OF THE INVENTION

1. Field of the Invention

This invention generally relates to a method for image processing, andmore particularly improvement in the modulation transfer function of animage.

2. Description of the Prior Art

Recently, apparatuses for capturing an image are popular and quite a fewexist, e.g. a scanner, a digital camera, etc. A light sensing devicecaptures light through optical lenses, which an object radiates orreflects from another light source, and obtains a formation of image ofthe object. A CCD (charge-coupled device, CCD) device or a CMOS(complementary metal-oxide-semiconductor) device is a common lightsensing device that can capture the light to transfer an image digitaldata.

The image data can not be completed equal to that which is seen with thehuman eye, due to the physical limitations or defects of the apparatus.For example, the modulation transfer function of the captured imagereduces the result from an insufficient contrast, a blurred formation ofimages and so forth. The limitations are diffraction, aberrations,chromatism, and the scattering from an external light source and so on.Some limitations can be solved by means of amending the design of theapparatus. For example: amending the curvature of the lenses or theoptic axis to solve the aberration; changing the material or thecombination of lenses to solve the chromatism; employing rough innersurfaces on the apparatus and spreading black material on the innersurfaces thereof to reduce the scattering of external light. Although,this handling improves the quality of the captured image, but it can nottotally overcome the effects and limitations thereof. The captured imagestill debases a definition and a contrast with the effects.

The original data (equal to that which is seen with the human eye) ofthe image is not destroyed but hidden by the effects, e.g. a differencein the brightness between pixels in a border between an object and thebackground of the image. The ratio in brightness relatively becomessmaller and not so obvious, due to joining the effect into the originaldata. Hence, the captured image is blurred. The image data comprises theoriginal data and the unneeded external data.

The advantage of the digital image is that the digital image canfunction with a logical operation and a logical analysis. Hence, thedigital image can be processed with software for enhancing the contrastor increasing the brightness thereof. Nevertheless, the image withenhanced contrast increases the difference in brightness and aliasing,which then becomes non-distinct due to processing the contrast thereof.

To eliminate external data is hard. The characteristics of external datado not affect the difference between pixels in the original data of theimage. Furthermore, the digital image can function with a logicaloperation to amend the image data. Therefore, the border between anobject and the background of the image can be determined with thecharacteristic and then the border therebetween is processed foramending the border. Moreover, the amending process is only processedwith the border therebetween and not with the object and the backgroundin the image. Hence, the amending process does not change the data ofthe image expect the border and does not cause a problem with aliasing.In the conventional art, the border is determined with 9 pixels, but inthe present invention, the border can be determined with less pixels andthe efficiency of the operation is improved.

SUMMARY OF THE INVENTION

In the conventional art, the captured image is not identical with theoriginal image in sharpness or definition. Furthermore, the capturedimage is amended with processing image software, which has the aliasingproblem. One of objectives of the present invention is to provide amethod for improving the modulation transfer function of an image.

Another objective of present invention is to employ a method foramending the border of an object in the image without changing theborder in the image. Therefore, the amended image does not bring aboutthe problem of aliasing.

Another objective of present invention is to amend the border of anobject for reducing the width of the blurred border.

Another objective of the present invention is to improve the quality ofthe image with less data and increase the efficiency of the processingimage for economizing on time.

As aforementioned, the present invention provides a method for improvingthe modulation transfer function of an image. The present inventionemploys a varying brightness characteristic on the border of an objectin an image to determine the border and to amend the border of the imagein order to increase the modulation transfer function (MTF) of theimage. The width (i.e. the amount of pixels) in the border becomesnarrow and so the image becomes distinct. The data of the object doesnot change due to amending the border of the object in the image.Therefore, the image does not increase the aliasing after amended.Moreover, the method needs less data to amend the MTF of the image andincreases the processing efficiency for economizing on time.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1A is a flow chart of amending vertical border;

FIG. 1B is a flow chart of amending vertical border with functions;

FIG. 2A is a flow chart of amending horizontal border;

FIG. 2B is a flow chart of amending horizontal border with functions;

FIG. 3A is a flow chart of amending horizontal vertical border;

FIG. 3B is a flow chart of amending horizontal vertical border withfunctions; and

FIG. 4A to 4D is a diagram before amended and after amended,respectively.

DESCRIPTION OF THE PREFERRED EMBODIMENT

Some sample embodiments of the invention will now be described ingreater detail. Nevertheless, it should be recognized that the presentinvention can be practiced in a wide range of other embodiments besidesthose explicitly described, and the scope of the present invention isexpressly not limited expect as specified in the accompanying claims.

The data of an image comprises respective color values of the primarycolors of red, green, and blue. The displaying color of the image mixesthe respective colors thereof. Hence, the method of improving the MTF ofthe image employs the respective color values of three primary colors(RGB) to determine a border of an object in the image.

In one preferred embodiment, X(i,j) means a color value of one of red,green and blue, and “(i,j)” of X(i,j) means a coordinate (i,j). The “i”of (i,j) means the coordinate value in the vertical axis, and the “j”means the coordinate value in the horizontal axis.

Referring to FIG. 1A, shows a flow chart of amending vertical border 100in the preferred embodiment. First, determining vertical border 102determines with the color values X(i−1,j), X(i,j) and X(i+1,j) of threesuccessive pixels at same color in a vertical axis. If it is a verticalborder, the color value gradually reduces or increases, i.e. thebrightness of the color gradually reduces or increases. Therefore, thevertical border satisfies the condition of X(i−1j)<X(i,j)<X(i+1,j) orX(i−1,j)>X(i,j)>X(i+1,j). The function of determining vertical border102 can be written as:[X(i+1,j)−X(i,j)][X(i−1j)−X(i−1,j)]>0   (1)

If Eq. (1) is false, amending horizontal border 200 proceeds. If Eq. (1)is true, the horizontal vertical border 104 determination proceeds. Thefunction of determining horizontal vertical border 104 can be writtenas:[X(i,j+1)−X(i,j)][X(i,j)−X(i,j−1)]>0   (2)

If Eq. (2) is true, amending the horizontal vertical border 300proceeds. If Eq. (2) is false, value deflection 106 determinationproceeds. Determining value deflection 106 determines whether the pixelcolor value of X(i,j) is nearer to the color value of X(i+1,j) orX(i−1,j). The function of determining the value deflection 106 can bewritten as:abs[X(i+1,j)−X(i,j)]>abs[X(i−1,j)−X(i,j)]  (3)

If Eq. (3) is true, it means the pixel color value of X(i,j) is nearerto X(i−1,j), and the pixel value of X(i,j) is replaced with the averageof X(i,j) and X(i−1,j). If Eq. (3) is false, it means the pixel colorvalue of X(i,j) is nearer to X(i+1,j), the pixel value of X(i,j)replaces with the average of X(i,j) and X(i+1,j). When the pixel colorvalue of X(i,j) is nearer to X(i−1,j), the effect in X(i,j) of X(i−1,j)is bigger than of X(i+1,j), i.e. X(i,j) and X(i−1,j) belong to a samebright area or dark area but X(i,j) slightly shifts to X(i+1,j) due tothe effect of X(i+1,j). Therefore, X(i,j) must be amended to X(i−1,j).Similarly, when the pixel color value of X(i,j) is nearer to X(i+1,j),X(i,j) must be amended to X(i+1,j). In short, X(i,j) is nearer to aminimum of X(i−1,j) and X(i+1,j), X(i,j) is amended to be nearer theminimum 108; X(i,j) is nearer to a maximum of X(i−1,j) and X(i+1,j),X(i,j) is amended to be nearer the maximum 110. Hence, X(i,j) in blurredbright area is amended to become brighter ,or X(i,j) in blurred darkarea is amended to become darker for increasing the sharpness of theborder in the image. The flow chart for amending the vertical borderwith functions is as shown in FIG. 1B.

Referring to FIG. 2A, it is a flow chart for amending the horizontalborder 200 in another preferred embodiment of this invention. First,determining the horizontal border 202 is done by using Eq. (1). If it istrue, amending the vertical border 100 proceeds. If it is false,determining horizontal 204 proceeds to determine the horizontal borderwith the color values X(i,j−1), X(i,j) and X(i,j+1) of three successivepixels with the same color in a horizontal axial. If it is a horizontalborder, the color value is gradually reduced or increased, i.e. thebrightness of the color gradually reduces or increases. Therefore, thehorizontal border satisfies the condition of X(i,j−1)<X(i,j)<X(i,j+1)orX(i,j−1)>X(i,j)>X(i,j+1). The horizontal border is determined by Eq.(2).

If Eq. (2) is false, not amending 206 is proceeds-due to the pixel (i,j)not a horizontal border or a vertical border. If it is true, determiningvalue deflection 208 proceeds to determine the pixel color value ofX(i,j) which is nearer to the pixel color value of X(i,j+1) or X(i,j−1).The function of determining value deflection 208 can be written as:abs[X(i,j+1)−X(i,j)]>abs[X(i,j)−X(i,j−1)]  (4)

If Eq. (4) is true, it means the pixel color value of X(i,j) is nearerto X(i,j−1), the pixel value of X(i,j) replaces the average of X(i,j)and X(i,j−1). If it is false, it means the pixel color value of X(i,j)is nearer to X(i,j+1), the pixel value of X(i,j) replaces the average ofX(i,j) and X(i,j+1). When the pixel color value of X(i,j) is nearer toX(i,j−1), the effect in X(i,j) of X(i,j−1) is bigger than of X(i,j+1),i.e. X(i,j) and X(i,j−1) belongs to the same bright area or dark areabut X(i,j) slightly shifts to X(i,j+1) due to the effect of X(i,j+1).Therefore, X(i,j) is amended to X(i,j−1). Similarly, when the pixelcolor value of X(i,j) is nearer to X(i,j+1), X(i,j) is amended toX(i,j+1). In short, X(i,j) is nearer to a minimum of X(i,j−1) andX(i,j+1), X(i,j) is amended to be nearer the minimum 210; X(i,j) isnearer to a maximum of X(i,j−1) and X(i,j+1), X(i,j) is amended to benearer the maximum 212. Hence, X(i,j) in blurred bright area is amendedto become brighter, or X(i,j) in blurred dark area is amended to becomedarker to increase the sharpness of the border in the image. The flowchart for amending the horizontal border with functions is as shown inFIG. 2B.

Referring to FIG. 3A, it is a flow chart of amending horizontal verticalborder 300 in a still another preferred embodiment of this invention.First, determining the vertical border 302 with Eq. (1). If it is false,amending the vertical border 200 proceeds. If it is true, determiningthe horizontal vertical 304 proceeds with Eq. (2). If Eq. (2) is true,determining the horizontal value deflection 306 proceeds, i.e. X(i,j) isdetermined nearer to the pixel color value of X(i+1,j) or X(i−1,j) withEq. (3) in a horizontal direction.

If Eq. (3) is true, it means the pixel color value of X(i,j) is nearerto X(i−1,j) in the horizontal direction. Furthermore, determining thevertical value deflection 308 determines X(i,j) nearer to the pixelcolor value of X(i,j+1) or X(i,j−1) with Eq. (4) in a verticaldirection. If Eq. (4) is true, it means that the pixel color value ofX(i,j) is nearer to X(i−1,j) in the horizontal direction and X(i,j−1) inthe vertical direction. Therefore, the X(i,j) replaces the average ofX(i,j), X(i−1,j) and X(i,j−1). If Eq. (4) is false, it means that thepixel color value of X(i,j) is nearer to X(i−1,j) in the horizontaldirection and X(i,j+1) in the vertical direction. Therefore, the X(i,j)is replaced with the average of X(i,j), X(i−1,j) and X(i,j+1).

If Eq. (3) is false, it means the pixel color value of X(i,j) is nearerto X(i+1,j) in the horizontal direction. Furthermore, determiningvertical value deflection 310 determines X(i,j) nearer to the pixelcolor value of X(i,j+1) or X(i,j−1) with Eq. (4) in a verticaldirection. If Eq. (4) is true, it means that the pixel color value ofX(i,j) is nearer to X(i+1,j) in the horizontal direction and X(i,j−1) inthe vertical direction. Therefore, the X(i,j) is replaced with theaverage of X(i,j), X(i+1,j) and X(i,j−1). If Eq. (4) is false, it meansthat the pixel color value of X(i,j) is nearer to X(i+1,j) in thehorizontal direction and X(i,j+1) in the vertical direction. Therefore,the X(i,j) is replaced with the average of X(i,j), X(i+1,j) andX(i,j+1).

Referring to FIG. 3B, X(i,j) is nearer to a minimum of X(i−1,j) andX(i+1,j) in the horizontal direction and a minimum of X(i,j−1) andX(i,j+1) in the vertical direction, X(i,j) is amended to be nearer tothe minimum 312 in the horizontal direction and in the verticaldirection. X(i,j) is nearer to a minimum of X(i−1,j) and X(i+1,j) in thehorizontal direction and a maximum of X(i,j−1) and X(i,j+1), X(i,j) isamended to be nearer to the minimum in horizontal direction and themaximum in the vertical direction 314. X(i,j) is nearer to a maximum ofX(i−1,j) and X(i+1,j) in the horizontal direction and a maximum ofX(i,j−1) and X(i,j+1) in the vertical direction, X(i,j) is amended to benearer to the maximum in the horizontal direction and in the verticaldirection 318. X(i,j) is nearer to a maximum of X(i−1,j) and X(i+1,j) inthe horizontal direction and a minimum of X(i,j−1) and X(i,j+1), X(i,j)is amended to be nearer to the maximum in horizontal direction and theminimum in the vertical direction 316.

Any pixel in an image can be determined in a horizontal border, avertical border, a horizontal vertical border, or not with theaforementioned preferred embodiments. The dark pixel in the border isamended to be darker and brighter pixels in the border are amended to bebrighter to increase the sharpness of the border and the MTF of theimage. FIG. 4A to 4B is diagram before being amended and after beingamended, respectively.

Moreover, specific weights of X(k,j) and X(i,m) are adjustable. X(i,j)is replaced with.alpha . . . times.X(i,j)+.beta . . . times.X(k,j)+.gamma . . .times.X(i,m)   (5)

Wherein, X(k,j) is the adjacent pixel of X(i,j) in the horizontaldirection with the nearer value of the same color; X(i,m) is theadjacent pixel of X(i,j) in the vertical direction with the nearer valueof the same color. The alpha., beta., and gamma. are of a specificweight respectively, between 0 and 1, and .alpha.+.beta.+.gamma.=1

If X(i,j) is only amended in the horizontal border, .beta.=0. If X(i,j)is only amended in the vertical border, .gamma.=0. A preferred amendmentis obtained by a different specific weight according to differentstates.

The method for improving MTF of an image in this invention can beemployed in the width that exceeds three pixels in the horizontal orvertical direction. For example, the successive five pixels of X(i−2j),X(i−1,j), X(i,j), X(i−1,j) and X(i+2,j) are in a border of an object inan image, i.e. the color value gradually increases or decreases. Theamended color value of X(i,j) is the average of the non-amended X(i,j)and the nearer color value of the non-amended adjacent pixel. Hence, theamended image is easier to differentiate between an object and abackground and the MTF of the amended image increases. Furthermore, thewidth of the border efficiently narrows, as shown in FIG. 4C and FIG.4D.

In regard to an increasingly changeable color image, a pixel in anon-border area may be determined as a pixel in a border with only onecolor of red, green and blue. Hence, the gray scale portion in the imageis only determined to avoid a wrong interpretation. The gray scaleportion means the portion that one color value of red, green and bluediffers less than .delta. from the other color value thereof. Thefunction of determining gray scale can be written as:Max[abs(Xr−Xg),abs(Xg−Xb),abs(Xb−Xr)]<.delta.   (6)

Wherein, the Xr, Xg, and Xb are the color value of red, green, and blue,respectively. The “abs” means absolute value. The “.delta.” means thelimitation range of determining the gray scale, e.g. .delta.=21. Hence,amending the vertical border 100, amending the horizontal border 200,and amending the horizontal vertical border 300 proceeds if thedifference between one color value of red, green, and blue and the othercolor value thereof is less than 21 to avoid the wrong interpretation.

Although specific embodiments have been illustrated and described, itwill be obvious to those skilled in the art that various modificationsmay be made without departing from what is intended to be limited solelyby the appended claims.

1-18. (canceled)
 19. A method, comprising: identifying a border of anobject in an image; identifying a pixel that is in the border; comparinga color or brightness value of the identified border pixel to a color orbrightness values of two or more other selected pixels; and amending thecolor or brightness value of the identified border pixel according tothe comparison to increase the modulation transfer function.